package momo.app.comms;

import java.util.LinkedHashMap;
import java.util.Map;

public class MsgHistory<K, V> extends LinkedHashMap<K, V> implements Map<K, V>
{
	private static final long serialVersionUID = 465215943102114143L;
	
//	500 -> 58-60 MB
	private static final int MAX_ENTRIES = 5000; 

	protected boolean removeEldestEntry(Entry<K, V> eldest) {
		return size() > MAX_ENTRIES;
	}
	
}//end of class MsgHistory

